<template>
  <el-row :gutter="20">
    <el-col :span="6" v-for="item in list" :key="item.id">
      <div class="grid-content">
        <div>
          <i
            class="iconfont"
            :class="item.icon"
            :style="{ color: item.color }"
          ></i>
        </div>
        <div>
          <p>{{ item.text }}</p>
          <h3>{{ item.num }}</h3>
        </div>
      </div>
    </el-col>
  </el-row>
</template>

<script>
export default {
  props: {
    list: {
      type: Array,
      default: () => []
    }
  }
}
</script>

<style lang="less" scoped>
.grid-content {
  background-color: #fff;
  border-radius: 5px;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 20px 0;
  i {
    font-size: 45px;
  }
  p {
    color: #ccc;
    margin-bottom: 5px;
    font-size: 16px;
  }
  h3 {
    font-size: 18px;
    font-weight: bold;
  }
}
</style>
